<?php


namespace Mslynn\Log\Observer;


use Mslynn\Log\Logger\Register\Logger;

class RegisterSuccess implements \Magento\Framework\Event\ObserverInterface
{
    protected $_logger;

    public function __construct(
        Logger $logger
    )
    {
        $this->_logger = $logger;
    }

    public function execute(\Magento\Framework\Event\Observer $observer)
    {

        $customer =$observer->getData('customer');
        /**
         *@var \Magento\Customer\Model\Data\Customer $customer
         */
        $this->_logger->info('新增注册',[$customer->getEmail()]);
    }
}